package ie.dkit.java3Demulation.objects3d;

import java.util.ArrayList;
import java.util.Collection;

import ie.dkit.java3Demulation.objects.Point;
import ie.dkit.java3Demulation.transforming.Transformable;

/**
 * @author Sebastian Ruehl
 * 
 * This program is free software; you can redistribute it and/or modify it under
 * the terms of the GNU General Public License as published by the Free Software
 * Foundation
 * 
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
 * details.
 * 
 * You should have received a copy of the GNU General Public License along with
 * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
 * Place, Suite 330, Boston, MA 02111-1307 USA
 */
public class Point3D extends Point implements Transformable {
	private double m_Z;

	private Point3D m_RotationPoint;

	public Point3D() {
		m_PointName = "Point3D";
	}

	/**
	 * @param m_x
	 * @param m_y
	 * @param m_z
	 */
	public Point3D(double m_x, double m_y, double m_z) {
		super(m_x, m_y);
		m_Z = m_z;
	}

	/**
	 * @return the m_Z
	 */
	public double getZ() {
		return m_Z;
	}

	/**
	 * @param z
	 *            the m_Z to set
	 */
	public void setZ(double z) {
		m_Z = z;
	}

	public void setCoordinate(Point3D point) {
		m_X = point.m_X;
		m_Y = point.m_Y;
		m_Y = point.m_Z;
	}

	public Collection<Point3D> getPoints() {
		Collection<Point3D> returnValue = new ArrayList<Point3D>();
		returnValue.add(this);
		return returnValue;
	}

	public Point3D getRotationPoint() {
		return m_RotationPoint;
	}

	public void setRotationPoint(Point3D point3D) {
		m_RotationPoint = point3D;
	}
}
